<div class="layui-fluid">
    <div class="layui-card">
        <div class="layui-card-body">
            <table id="financial-point-detail" lay-filter="financial-point-detail"></table>
        </div>
    </div>
</div>
<script type="text/html" template lay-done="layui.data.sendParams(d.params)"></script>
<script>
    layui.data.sendParams = function (params) {
        layui.use(['admin', 'table'], function () {
            var admin = layui.admin,
                view = layui.view,
                table = layui.table,
                api_action_url = layui.setter.apiHost + '/financial/point_detail';

            //表格操作
            table.render({
                elem: '#financial-point-detail',
                url: api_action_url,
                where: {m_id: params.m_id},
                cols: [[
                    {field: 'id', title: 'ID', width: 80},
                    {field: 'amount', title: '金额', width: 100},
                    {field: 'balance', title: '积分余额', width: 100},
                    {field: 'event', title: '类型', width: 100},
                    {field: 'detail_no', title: '单号', width: 200},
                    {field: 'note', title: '备注'},
                    {field: 'created_at', title: '时间', width: 170},
                ]],
                page: true
            });
        });
    }
</script>
